package com.suli.account.config;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.socket.server.standard.ServerEndpointExporter;

/**
 * @author admin
 * @version 1.0 <br/>
 * <p style="font-family:SimSun;font-weight:bold">时间:<br/>2022/2/3 17:08</p>
 */
@Configuration
public class WebSocketConfig {
    /**
     * 注入ServerEndpointExporter Bean对象,可以自动注册使用了@ServerEndpoint注解的Bean(将类交给Spring管理)
     * @return 返回对象
     */
    @Bean
    public ServerEndpointExporter serverEndpointExporter(){
        return new ServerEndpointExporter();
    }
}
